Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Frontend team #306

Closed
wants to merge 16 commits into from
Closed

Frontend team #306

wants to merge 16 commits into from

Conversation

daisycrego
Copy link
Contributor

No description provided.

daisycrego and others added 16 commits April 3, 2020 15:51
…or testing going forward, and can also be used to refactor existing tests/code.
… existing events. Each dashboard will have panels for all existing sensors.
… are no events then no dashboards are created on GF, if there is an event a dashboard is created on GF, if there is a sensor and event the sensor panel is added to the event dashboard.
Merge branch 'frontend-team' into grafana
- Update ag_data.models.AGSensor to include a __str__ method - needed for display purposes.
- Create a ModelForm to allow the user to select which sensors to include in a dashboard.
- Change some names in the Grafana API for clarity
- Modify Grafana.delete_all_panels (deleting by dashboard uid) to delete by dashboard name, because this will make the method more useful.
- Add Grafana.update_dashboard_panels(), which takes a dashboard/event name and array of sensors and updates the Event dashboard on Grafana with the new set of sensors.
- Add Grafana.get_all_sensors(), which returns a list of all current sensors in a given dashboard.
- Update GFConfig GET view to return data for each dashboard to the context, as well as DashboardSensorPanelsForm forms initialized with the existing sensors.
- Update gfconfig template to display a form for each dashboard listing all panels, with the panels actually present in the dashboard checked.
- Add Update/Refresh/Delete buttons to sensor forms.
… its name and sensor(s) are passed to the template and displayed.
…rect ModelForm type was passed to the template.
…ethod to Grafana API to return dashboard url when passed a dashboard name. Pass urls in the context and display them in the template.
…ate button is pressed, dashboard is updated to include only the currently selected sensor panels.
…was failing on Travis builds only, not on local.
…tipleChoiceField to provide labels for the sensors displayed by DashboardSensorPanelsForm. This is a better alternative to adding a __str__ method to the AGSensor model for processing form submissions. Remove __str__ method of ag_data.models.AGSensor. Add tests for Update Dashboard Panels to remove all panels, keep all panels, and keep only a subset of panels.
…shboard resets. Add a test which sets the panels in the dashboard to a subset of the total panels, then uses reset to restore all panels to the dashboard.
… Add test of delete feature which deletes a dashboard and confirms delete operation returns True
Issue #225: Creating a GFConfig triggers creation of Event dashboards/Sensor panels for all existing events/sensors. Issue #295: View Existing Dashboards in GFConfig view
@daisycrego daisycrego closed this Apr 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants